<?php
	$adminForm = new AdministratorForm(array('show_auth_fields'=>true, 'messages'=>$this->messages));
	// do this so we can get the error messages in the form
	if($this->adminProfile != null)
	{
		$isValid = $adminForm->isValid($this->adminProfile);
		$adminForm->populate($this->adminProfile);
	}

	$action = $this->url(array('controller'=>'index', 'action'=>'newadministrator'));
	$adminForm->setAction($action);
	//echo $adminForm->render_with_template("ksadminprofile.xhtml");
	echo $adminForm;
 ?>